﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Security.Principal;

namespace Ovvio.Business
{
    public class UserIdentity : IIdentity
    {
        private bool _isAuthenticated;
        private string _username;
        private int _id;
        private string _name;
        public UserIdentity(bool isAuthenticated, int id, string username, string name)
        {
            _id = id;
            _username = username;   
            _isAuthenticated = isAuthenticated;
            _name = name;
        }
        #region IIdentity Members

        public string Username { get { return _username; } }
        public int Id { get { return _id; } }

        public string AuthenticationType
        {
            get { return "Ovvio Authentication"; }
        }

        public bool IsAuthenticated
        {
            get { return _isAuthenticated; }
        }

        public string Name
        {
            get { return _name; }
        }

        #endregion
    }
}
